﻿<div class="page-title">
    Add Portfolio
</div>
<div class="numbered-title">
    <div class="numbered-title-number">1</div>
    <div class="numbered-title-text">
        <button class="btn-green" ng-click="portfolioAdd.downloadPortfolioUploadTemplate()">Download Template</button>
    </div>
</div>
<div class="numbered-title">
    <div class="numbered-title-number">2</div>
    <div class="numbered-title-text">
        <input type="file" id="portfolioFile" ng-file-select="portfolioAdd.onSelectExcel($files)" accept=".xls, .xlsx" style="font-size: 14px;" ng-model="portfolioAdd.fileName" />
        {{portfolioAdd.fileName}}
    </div>
</div>
<div class="numbered-title">
    <div class="numbered-title-number">3</div>
    <div class="numbered-title-text">Portfolio Name</div>
</div>
<div style="position: relative; height: 60px;">
    <div class="sarch-top" style="margin: 0 0 0 25px; position: absolute;">
        <div class="sustainalytics-searchbox" data-searchbox-service="PortfolioSearchBoxServiceAdapter"
             data-searchbox-searchempty data-searchbox-text="portfolioAdd.portfolioSearch">
            <input type="text" ng-maxlength="100" id="portfolioAddSearchInput" class="inp-search sustainalytics-searchbox-input" style="float: left;" ng-model="search.searchData" placeholder="Portfolio Name">
            <input type="button" id="searchPortfolioBtn" class="btn-search" style="float: left;" onclick="$('#portfolioAddSearchInput').focus();" ng-click="search.search(false)">
            <div class="clear">&nbsp;</div>
            <div class="search-results" ng-show="search.isVisible">
                <div class="search-results-inner sustainalytics-searchbox-results" style="height: 80px; overflow: auto;" ng-show="search.lastItemsCount > 0 || search.lastSkip > 0">
                    <a href="" ng-repeat="item in search.items" ng-click="portfolioAdd.selectPortfolioAdd(item); $parent.search.searchData = item.name; $parent.search.isVisible = false; $event.stopPropagation();"><span ng-bind-html="item.markedContent"></span> {{item.name}}</a>
                </div>
                <p style="text-align: center; color: white; font-weight: bold; padding:0 0 20px 0;" ng-show="search.skip == 0 && search.lastItemsCount == 0">
                    No matches found
                </p>
            </div>
        </div>
        <div class="clear">&nbsp;</div>
    </div>
</div>
<div class="clear"></div>
<div class="modal-sel-crit" style="margin-left: 26px;">
    <div class="numbered-title-text">Share</div>
    <a href="" class="info-lynk" title="When turned on the portfolio will be shared with all users in your group.">&nbsp;</a>
    <div style="display: inline-block; margin-left: 15px;">
        <div ng-init="selected" ng-switch on="portfolioAdd.isShared">
            <button ng-switch-when='false' ng-click='portfolioAdd.setShared()' class="switch-btn">Off</button>
            <button ng-switch-when='true' ng-click='portfolioAdd.setPrivate()' class="switch-btn_on">On</button>
        </div>
    </div>
</div><br /><br />
<button class="btn-green" ng-disabled="!(portfolioAdd.portfolioSearch).length" ng-click="portfolioAdd.savePortfolioFromUpload()">Save</button>
<button class="btn-green" ng-click="portfolioAdd.cancel()">Cancel</button>
